// app.js
import './utils/utils'
import './utils/http'
App({
  onLaunch() {
    this.getToken()
  },
  globalData: {},
  token: '',
  ref_token: '',
  getToken() {
    const token = wx.getStorageSync('token');
    this.token = token;
    const ref_token = wx.getStorageSync('ref_token');
    this.ref_token = ref_token;
  },
  setToken(token, ref_token) {
    wx.setStorageSync('token', token)
    this.token = token
    wx.setStorageSync('ref_token', ref_token)
    this.ref_token = ref_token
  }
})